<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>


<script>
  // 参数问题
  // 1.1.放入两个参数
  const sun = (num1, num2) => {
    return num1 + num2
  }

  // 1.2.放入一个参数 小括号可以省略
  const power = num => {
    return num * num
  }

  // 2
  // 2.1.函数块中多行代码
  const logTest = () => {
    console.log('Hello World');

    console.log('Hello Vuejs');
  }

  // 2.2.函数代码块中有一行代码
  // const mul = (num1, num2) => {
  //   return num1 * num2
  // }
  const mul = (num1, num2) => num1 * num2

  // const demo = () => {
  //   console.log('Hello Demo');
  // }
  const demo = () => console.log('Hello Demo')
  demo()
</script>
</body>
</html>